import request from '@/utils/request'

//添加员工
export const addStaff = data => {
  return request({
    url:'oa/personnel/addStaff',
    method:'post',
    data,
  })
}


//获取权限列表
export const getAuthList = query => {
  return request({
    url:'oa/personnel/authList',
    method: 'get',
    params: query
  })
}


//获取模块列表
export const getModelList = query => {
  return request({
    url:'oa/personnel/modelList',
    method: 'get',
    params: query
  })
}

//编辑权限
export const editAuth = data => {
  return request({
    url:'oa/personnel/editAuth',
    method:'post',
    data,
  })
}

//编辑模块

//编辑权限
export const editModel = data => {
  return request({
    url:'oa/personnel/editModel',
    method:'post',
    data,
  })
}

// 编辑用户信息
export const editStaffMsg = data => {
  return request({
    url:'oa/personnel/editStaffMsg',
    method:'post',
    data,
  })
}


//删除用户
export const delSatff = query => {
  return request({
    url:'oa/personnel/delStaff',
    method: 'get',
    params: query
  })
}
